package com.red.mapper;

import com.red.entity.House;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface HouseMapper {
    House[] selectHouses(@Param("size") int size, @Param("offset") int offset, @Param("status") String[] status);

    House selectByID(@Param("house_id") int house_id);

    int selectSize(@Param("status") String[] status);


    int insertHouse(
            @Param("house_name") String house_name,
            @Param("price") int price,
            @Param("address") String address,
            @Param("detailed_address") String detailed_address,
            @Param("description") String description
    );

    int deleteHouses(@Param("ids") List<Integer> ids);

    int updateHouse(House house);
}
